package com.lxyk.controller;


import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
//用于映射URL到控制器类 或方法上
@RequestMapping("/Test")
public class ControllerTest {
    @RequestMapping("/hello")
    public String index(Model modle)
    {
        modle.addAttribute("msg","controller");
        /*返回视图*/
        return "test01";
    }
}
